<?php 
include '../function.php';
print_r($_POST);
$from=$_POST["from"];
$to=$_POST["to"];
$content=$_POST["content"];
$bgId=$_POST["select"];
$insertId=addInfo($from,$to,$content,$bgId);
echo $insertId;
/*$url="background".$bgId.".php?object=$from&text=$content&name=$to";*/
$myDb=new DB();
$array=$myDb->queryOneData("select * from conInfo where id=$insertId limit 1");
$key=$array["conKey"];
$url="key.php?key=$key";
print_r($array);
header("Location: $url");
 ?>